import wepy from 'wepy'

export default class testMixin extends wepy.mixin {
  data = {
    goTopShow: false
  }
  onPageScroll (e) { // 获取滚动条当前位置
    // console.log(this.$parent.globalData.systemInfo.screenHeight, e.scrollTop, this.$parent.globalData.systemInfo.screenHeight < e.scrollTop)
    this.$apply(() => {
      if (this.$parent.globalData.systemInfo.screenHeight < e.scrollTop) {
        this.goTopShow = true
      } else {
        this.goTopShow = false
      }
    })
  }
}
